﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace NumericalMethod
{
    public partial class FloatingPoint : ContentPane
    {
        StatusForm mStatus;
        public FloatingPoint()
        {
            InitializeComponent();
        }
        public override void OnLoad()
        {
            mStatus = new StatusForm();
            Parent.Controls.Add(mStatus);
            //prepareData();
            mStatus.HidePanel(2);
        }
        private void btnAnswer_Click(object sender, EventArgs e)
        {
            if (txtInput.Text.Trim() != "")
            {
                lblAnswer.Text = Numbers.GetFloatingPointNumber(decimal.Parse(txtInput.Text)).ToString();
                mStatus.AppendOutput(txtInput.Text + " = " + lblAnswer.Text + " [Floating Point Number]");
            }
        }
    }
}
